odhcpd: remove confusing #defines
authorDavid Härdeman <[email protected]>
Tue, 30 Sep 2025 17:45:24 +0000 (19:45 +0200)
committerÁlvaro Fernández Rojas <[email protected]>
Wed, 1 Oct 2025 21:04:57 +0000 (23:04 +0200)
commit7328bfe40f810c8ca78c86ed4811eb742a9d3761
tree9dab7f4e48f7d70278c74bc324ee7a04de6d5200
parentcdb9e5b655fc6e7f4e9f340408e21231c943279c
odhcpd: remove confusing #defines

Right now, odhcpd.h contains lines like "#define hwaddr mac", which is a great
footgun when hacking on odhcpd (like when creating a function with a local
variable named "hwaddr" and later getting compiler errors talking about how
"mac" has the wrong type...in a function which has no variable named "mac").

So, remove these definitions. I'm not sure the chosen variable names are the
most descriptive, but I erred on the side of caution and picked the alternative
that required the least amount of changes. We can always change the names of
the variables later.

Signed-off-by: David Härdeman <[email protected]>
Link: https://github.com/openwrt/odhcpd/pull/261
Signed-off-by: Álvaro Fernández Rojas <[email protected]>
src/dhcpv6-ia.c
src/odhcpd.h
src/ubus.c